#include "S_42_AirFreshFanControl_doChange.h"
#include "property_decoder.h"
#include "spec.h"


void P_42_1_VerticalSwing_doChange(bool newValue)
{
	property_value_t thiz;
    memset(&thiz,0,sizeof(thiz));
#if 	PROPERTY_TYPE
	property_value_new_boolean(&thiz,newValue);
#else	
    thiz.format = PROPERTY_FORMAT_BOOLEAN;
    thiz.data.boolean.value = newValue;
#endif		
	
    if (send_property_changed(42, 1, &thiz) != MIIO_OK)
    {
        LOG_INFO("%s:send_property_changed failed!\n",__func__);
    }
}

void P_42_2_HorizontalSwing_doChange(bool newValue)
{
	property_value_t thiz;
    memset(&thiz,0,sizeof(thiz));
#if 	PROPERTY_TYPE
	property_value_new_boolean(&thiz,newValue);
#else	
    thiz.format = PROPERTY_FORMAT_BOOLEAN;
    thiz.data.boolean.value = newValue;
#endif		
	
    if (send_property_changed(42, 2, &thiz) != MIIO_OK)
    {
        LOG_INFO("%s:send_property_changed failed!\n",__func__);
    }
}

void P_42_3_VerticalPosition_doChange(int newValue)
{
	property_value_t thiz;
    memset(&thiz,0,sizeof(thiz));

	property_value_new_integer(&thiz,newValue);
	
	if (send_property_changed(42, 3, &thiz) != MIIO_OK)
    {
       LOG_INFO("%s:send_property_changed failed!\n",__func__);
    }
}

void P_42_4_HorizontalPosition_doChange(int newValue)
{
	property_value_t thiz;
    memset(&thiz,0,sizeof(thiz));

	property_value_new_integer(&thiz,newValue);
	
	if (send_property_changed(42, 4, &thiz) != MIIO_OK)
    {
       LOG_INFO("%s:send_property_changed failed!\n",__func__);
    }
}

void P_42_5_SoftWind_doChange(int newValue)
{
	property_value_t thiz;
    memset(&thiz,0,sizeof(thiz));

	property_value_new_integer(&thiz,newValue);
	
	if (send_property_changed(42, 5, &thiz) != MIIO_OK)
    {
       LOG_INFO("%s:send_property_changed failed!\n",__func__);
    }
}

void P_42_6_WindSensation_doChange(bool newValue)
{
	property_value_t thiz;
    memset(&thiz,0,sizeof(thiz));
#if 	PROPERTY_TYPE
	property_value_new_boolean(&thiz,newValue);
#else	
    thiz.format = PROPERTY_FORMAT_BOOLEAN;
    thiz.data.boolean.value = newValue;
#endif		
	
    if (send_property_changed(42, 6, &thiz) != MIIO_OK)
    {
        LOG_INFO("%s:send_property_changed failed!\n",__func__);
    }
}

void P_42_7_WindDirection_doChange(int newValue)
{
	property_value_t thiz;
    memset(&thiz,0,sizeof(thiz));

	property_value_new_integer(&thiz,newValue);
	
	if (send_property_changed(42, 7, &thiz) != MIIO_OK)
    {
       LOG_INFO("%s:send_property_changed failed!\n",__func__);
    }
}



